﻿package Message.Public
{
    import Framework.MQ.*;
    import Framework.Serialize.*;

    public class SGuildBossRewardInfo extends IMessageBase
    {
        public var playerId:int;
        public var resource:int;
        public var contribution:int;
        public var coin:int;
        public var items:Array;
        public var color:int;
        public const _type:int = 5077;
        public static var _regist:SGuildBossRewardInfo = new SGuildBossRewardInfo(true);

        public function SGuildBossRewardInfo(param1:Boolean = false)
        {
            if (param1)
            {
                MessageManager.instance().regist(this);
            }
            return;
        }// end function

        override public function getType() : int
        {
            return this._type;
        }// end function

        override public function clone() : IMessageBase
        {
            return new SGuildBossRewardInfo();
        }// end function

        override public function __write(param1:SerializeStream) : void
        {
            param1.writeInt(this.playerId);
            param1.writeInt(this.resource);
            param1.writeInt(this.contribution);
            param1.writeInt(this.coin);
            SeqPlayerItemHelper.write(param1, this.items);
            param1.writeInt(this.color);
            return;
        }// end function

        override public function __read(param1:SerializeStream) : void
        {
            this.playerId = param1.readInt();
            this.resource = param1.readInt();
            this.contribution = param1.readInt();
            this.coin = param1.readInt();
            this.items = SeqPlayerItemHelper.read(param1);
            this.color = param1.readInt();
            return;
        }// end function

    }
}
